package com.hfengxiang.example.canvasrotatedemo;

import android.graphics.Matrix;
import android.util.Log;

public class LogUtils {
    public static void printMatrix(Matrix matrix){
        float[] values = new float[9];
        matrix.getValues(values);
        StringBuilder sb = new StringBuilder();
        sb.append("\n").append("matrix:").append("\n");
        for (int i = 0; i < values.length; i++) {
            sb.append("\t")
                    .append("v[")
                    .append(i)
                    .append("]")
                    .append("=")
                    .append(values[i])
                    .append("\n");
        }
        Log.d("MATRIX",sb.toString());
    }
}
